package com.dfiov.cloud.msmtools.entity.vo.msbluetooth;


import io.swagger.annotations.ApiModel;
import lombok.Data;

@Data
@ApiModel("DK返回结果")
public class DkResult<T> {

    /**
     * 状态码
     */
    private int code;

    /**
     * 状态信息
     */
    private String msg;

    /**
     * 返回结果
     */
    private T data;

    public boolean isSuccess() {
        return code == 0;
    }

    public boolean isFailed() {
        return !isSuccess();
    }
}
